<?php
/**
 * Created by IntelliJ IDEA.
 * User: 张伯发
 * Date: 2019/7/31
 * Time: 15:41
 */

namespace App\Model\Dao\Demo;


use App\Model\Entity\Demo\Banner;
use Swoft\Bean\Annotation\Mapping\Bean;

/**
 * @Bean()
 * Class BannerDao
 * @package App\Model\Dao\Demo
 * @author 张伯发 2019/7/31 15:41
 */
class BannerDao
{


    /**
     *
     * @param $id
     * @return array
     * @throws \Swoft\Db\Exception\DbException
     * @author 张伯发 2019/7/31 15:42
     */
    public function findBanner($id) :array
    {
        return Banner::find($id)->toArray();
    }

}
